<@sys.appList channel=channel pageIndex=pageNum pageSize=numPerPage>
<div class="pageHeader card">
    <form class="pagerForm" autocomplete="off" onsubmit="return navTabSearch(this);" method="post">
        <#include "../include_page/parameters.html"/>
        <div class="searchBar">
            <ul class="searchContent">
                <li>
                    <label><@t.page 'channel'/>:</label>
                    <input type="text" name="channel" value="${channel!}"/>
                </li>
            </ul>
            <div class="subBar">
                <ul>
                    <li>
                        <button type="submit" class="buttonActive"><@t.page 'button.search'/></button>
                    </li>
                </ul>
            </div>
        </div>
    </form>
</div>
<@sys.authorized roleIds=admin.roles urls='sysApp/add,sysApp/delete,sysAppToken/list,sysApp/view,sysApp/issueParameters'><#assign authorizedMap=map/></@sys.authorized>
<div class="card">
    <div class="panelBar">
        <ul class="toolBar">
        <#if authorizedMap['sysApp/add']>
            <li><a href="sysApp/add.html" target="navTab" rel="sysApp/add"><i class="icon-plus-sign-alt icon-large"></i><@t.page 'app.add'/></a></li>
        </#if>
        </ul>
    </div>
    <table class="table" width="100%" layoutH>
        <thead>
            <tr>
                <th><@t.page 'channel'/></th>
                <th><@t.page 'app.key'/></th>
                <th><@t.page 'app.secret'/></th>
                <th><@t.page 'operate'/></th>
            </tr>
        </thead>
        <tbody>
            <#list page.list as a>
            <tr>
                <td>${a.channel!}</td>
                <td>${a.appKey!}</td>
                <td>
                    <#if authorizedMap['sysApp/view']>
                        <a href="sysApp/view.html?id=${a.id}" class="btnText" target="dialog" rel="sysApp"><@t.page 'app.view_secret'/></a>
                    </#if>
                </td>
                <td>
                    <#if authorizedMap['sysApp/add']>
                        <a href="sysApp/add.html?id=${a.id}" class="edit btnText blue" target="navTab" rel="sysApp/edit"><i class="icon-edit icon-large"></i><@t.page 'app.edit'/></a></li>
                    </#if>
                    <#if authorizedMap['sysApp/issueParameters']>
                        <a href="sysApp/issueParameters.html?id=${a.id}" class="btnText green" target="dialog" width="600" height="200" mask="true"><@t.page 'app.issue'/></a>
                    </#if>
                    <#if authorizedMap['sysAppToken/list']>
                        <a href="sysAppToken/list.html?appId=${a.id}" class="btnText" target="navTab" rel="sysAppToken/list"><@t.page 'app.token'/></a>
                    </#if>
                    <#if authorizedMap['sysApp/delete']>
                        <a href="sysApp/delete?id=${a.id}&_csrf=<@tools.csrfToken admin=true/>" class="btnText warn" title="<@t.page 'confirm.delete'/>" target="ajaxTodo"><i class="icon-trash icon-large"></i><@t.page 'button.delete'/></a></li>
                    </#if>
                </td>
            </tr>
            </#list>
        </tbody>
    </table>
    <#include "../include_page/page.html"/>
</div>
</@sys.appList>